"""
Django settings for finSentiment project.

For more information on this file, see
https://docs.djangoproject.com/en/1.7/topics/settings/

For the full list of settings and their values, see
https://docs.djangoproject.com/en/1.7/ref/settings/
"""

# Build paths inside the project like this: os.path.join(BASE_DIR, ...)
import os
BASE_DIR = os.path.dirname(os.path.dirname(__file__))


# Quick-start development settings - unsuitable for production
# See https://docs.djangoproject.com/en/1.7/howto/deployment/checklist/

# SECURITY WARNING: keep the secret key used in production secret!
SECRET_KEY = 'vee-gtz0@fi0f-u+*!b!&gdz&_jqh%fj^^p147f_2to_x^oo@!'

# SECURITY WARNING: don't run with debug turned on in production!
DEBUG = True

TEMPLATE_DEBUG = True

ALLOWED_HOSTS = []


# Application definition

INSTALLED_APPS = (
    'django.contrib.admin',
    'django.contrib.auth',
    'django.contrib.contenttypes',
    'django.contrib.sessions',
    'django.contrib.messages',
    'django.contrib.staticfiles',
    'twitterSentiment',
    'django_extensions',
)

IPYTHON_ARGUMENTS = [
            '--ext', 'django_extensions.management.notebook_extension',
                '--profile=phd',
                    '--debug'
                    ]

MIDDLEWARE_CLASSES = (
    'django.contrib.sessions.middleware.SessionMiddleware',
    'django.middleware.common.CommonMiddleware',
    'django.middleware.csrf.CsrfViewMiddleware',
    'django.contrib.auth.middleware.AuthenticationMiddleware',
    'django.contrib.auth.middleware.SessionAuthenticationMiddleware',
    'django.contrib.messages.middleware.MessageMiddleware',
    'django.middleware.clickjacking.XFrameOptionsMiddleware',
)

ROOT_URLCONF = 'finSentiment.urls'

WSGI_APPLICATION = 'finSentiment.wsgi.application'


# Database
# https://docs.djangoproject.com/en/1.7/ref/settings/#databases

DATABASES = {

#python3 mysql requires mysql python3 connector
#see https://www.evernote.com/shard/s33/sh/e6cc5aa3-fe49-46d3-b0f0-9505e098987f/f598c915daf3ad5d3552b2212573fc66
    'default': {
        'ENGINE': 'mysql.connector.django',
        'NAME': 'finsentimentdb',
        'USER': 'tarek',
        'PASSWORD': 'TRhmyxpDobpi0gjt08Ja',
        'HOST': '',
        'PORT': '',
        'OPTIONS': {'charset': 'utf8mb4'},
        'CONN_MAX_AGE': None,
    }
}

# Internationalization
# https://docs.djangoproject.com/en/1.7/topics/i18n/

LANGUAGE_CODE = 'en-us'

TIME_ZONE = 'America/Chicago'

USE_I18N = True

USE_L10N = True

USE_TZ = True


# Static files (CSS, JavaScript, Images)
# https://docs.djangoproject.com/en/1.7/howto/static-files/

STATIC_URL = '/static/'

STATICFILES_DIRS = (
   '/usr/lib/python3.4/site-packages/django/contrib/admin/static/admin','/home/tarek/ownCloud/phd/www/static')

TEMPLATE_DIRS = (
    os.path.join(BASE_DIR,  'templates'),
)
